package service.impl;

import bean.pojo.GdOrder;
import dao.GdOrderMapper;
import org.springframework.stereotype.Service;
import service.GdOrderService;

import javax.annotation.Resource;
import java.util.List;

@Service
public class GdOrderServiceImpl implements GdOrderService {

    @Resource
    private GdOrderMapper gdOrderMapper;

    /**
     * 添加订单
     * @param pojo
     * @return
     */
    public boolean insert(GdOrder pojo){
        return gdOrderMapper.insert(pojo)>0;
    }

    public boolean insertList(List< GdOrder> pojos){
        return gdOrderMapper.insertList(pojos)>0;
    }

    public List<GdOrder> select(GdOrder pojo){
        return gdOrderMapper.select(pojo);
    }

    /**
     * 修改订单
     * @param pojo
     * @return
     */
    public boolean update(GdOrder pojo){
        return gdOrderMapper.update(pojo)>0;
    }

}
